﻿using System;

namespace DotNetRepository
{
    public interface IEntityRef<TEntity> : IEntityRef
        where TEntity : class, IEntity
    {
        new TEntity Value { get; set; }
    }

    public interface IEntityRef
    {
        IEntity Value { get; }
        Guid ID { get; set; }
        Guid PreviousID { get; }
        IEntity PreviousValue { get; }
        bool PreviousValueIsCached { get; }
        void ResetPreviousValue();
        bool IsCached { get; }
        bool AllowNull { get; }
        bool ReadOnly { get; }
    }
}
